Determine 32bit or 64bit mode of python shellΒΆ

Determine if the python shell is executing
in 32bit or 64bit mode on operating system.
import struct

print(struct.calcsize("P") * 8)

Output:

64